package com.lujieni.springbootsecurity.controller;

import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @Author：小鹿爱吃鱼
 * @Date: 2025/5/28 22:20
 * @Description:
 */
@RestController
@RequestMapping("/permission")
public class PermissionController {

    @GetMapping("/hello")
    @PreAuthorize("@ss.hasAnyRoles('it_depart_manager1','it_depart_manager')")
    public String hello() {
        return "Hello It manager";
    }

}
